Skip to content

Add copilot-setup-steps.yml for full agentic PR reviews#288

Closed
AlBurns-MSFT wants to merge 2 commits into
mainfrom
add-copilot-setup-steps
Closed

Add copilot-setup-steps.yml for full agentic PR reviews#288
AlBurns-MSFT wants to merge 2 commits into
mainfrom
add-copilot-setup-steps

Conversation

@AlBurns-MSFT
Copy link
Copy Markdown
Collaborator

Problem

Recent PRs show the warning:

Copilot was unable to run its full agentic suite in this review.

This happens because the repo lacks a .github/copilot-setup-steps.yml file. Without it, Copilot Code Review cannot spin up a runner environment and falls back to limited static diff analysis.

Fix

Add a minimal copilot-setup-steps.yml that checks out the repo. Since this is a docs-only repo (Markdown TSGs), no build tools or dependencies are needed — just a checkout gives Copilot full repo context for agentic reviews (cross-file references, link validation, structural analysis).

References

Without this file, Copilot Code Review falls back to limited static
analysis and shows a warning: 'Copilot was unable to run its full
agentic suite in this review.' Adding a minimal setup that checks out
the repo gives Copilot the context needed for full reviews.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 20, 2026 15:41
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Adds a .github/copilot-setup-steps.yml file intended to enable GitHub Copilot Code Review’s full agentic runner-based analysis by providing minimal environment setup steps.

Changes:

  • Introduces a Copilot setup steps configuration file under .github/.
  • Adds a single checkout step to provide full repository context to the agentic reviewer.

Comment thread .github/copilot-setup-steps.yml Outdated
Comment thread .github/copilot-setup-steps.yml Outdated
copilot-setup-steps:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
@AlBurns-MSFT
Copy link
Copy Markdown
Collaborator Author

Regarding the two review comments:

1. Format concern ("not a GitHub Actions workflow") — This is incorrect. The official GitHub docs confirm that copilot-setup-steps.yml uses the standard workflow format with on:, jobs:, and runs-on:. That's how you specify the runner environment. The warning on this PR is expected — the file only takes effect once merged to the default branch.

2. SHA pinning for actions/checkout — Fair hardening suggestion but low-risk here: this step only runs in the Copilot review sandbox (not CI), and actions/checkout is a first-party GitHub action. Using @v4 is the convention in GitHub's own docs for this file. Happy to pin if reviewers feel strongly.

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

@1008covingtonlane 1008covingtonlane left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for taking this on — the warning is annoying and the intent is right. However, this PR as written will not fix it. Two blocking issues per the official docs:

1. Wrong path. The file must be at .github/workflows/copilot-setup-steps.yml, not .github/copilot-setup-steps.yml. Copilot looks for it as a GitHub Actions workflow file. At the current path it will be ignored and the warning will keep firing.

2. Wrong structure. The contents are not a valid GitHub Actions workflow. It needs a jobs.copilot-setup-steps job with runs-on, not a bare top-level steps:. The job name is significant — Copilot specifically looks up the job named copilot-setup-steps.

The minimal correct file for a docs-only repo would be:

name: "Copilot Setup Steps"

on:
  workflow_dispatch:
  push:
    paths:
      - .github/workflows/copilot-setup-steps.yml
  pull_request:
    paths:
      - .github/workflows/copilot-setup-steps.yml

jobs:
  copilot-setup-steps:
    runs-on: ubuntu-latest
    permissions:
      contents: read
    steps:
      - uses: actions/checkout@v4

The on: block lets the workflow run as a normal Actions check so you can verify it actually works before merging.

Side note (non-blocking): the docs explicitly say "If you do not check out your code, Copilot will do this for you." So for a docs-only repo with no install steps, you may not need this file at all — the warning in the linked PR #287 might be from an older PR before whatever ships full agentic mode by default, or from a different cause. Worth confirming the warning actually goes away after merging a corrected version before assuming this is the fix.

@AlBurns-MSFT
Copy link
Copy Markdown
Collaborator Author

Closing this PR. I created this because I saw the automatic copilot reviews outputting failure messages instead of running. You can see some of them in the actions history: https://github.com/Azure/AzureLocal-Supportability/actions

You'll see they appeared to be transient and many have succeeded since the failures. I am thinking this is not an issue with out config it's was some transient issue outside of our control. Wrong change + transient external problem = closed PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants